package com.youseu.taoliving.commodity.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.youseu.common.utils.PageUtils;
import com.youseu.taoliving.commodity.entity.CategoryEntity;
import com.youseu.taoliving.commodity.vo.Catalog2Vo;

import java.util.List;
import java.util.Map;

/**
 * 商品分类表
 *
 * @author tao
 * @email tao@gmail.com
 * @date 2024-07-29 12:20:44
 */
public interface CategoryService extends IService<CategoryEntity> {

    PageUtils queryPage(Map<String, Object> params);

    //返回带有层级关系的分类结果
    List<CategoryEntity> listTree();

    //获取层级分类id数组
    Long[] getCascadedCategoryId(Long categoryId);

    //获取一级分类
    List<CategoryEntity> getFirstLevelCategories();

    //二三级分类
    Map<String,List<Catalog2Vo>> getCatalogJson();
}

